package com.medical.data.controller;


import com.medical.data.domain.DataCollector;
import com.medical.data.domain.ProjectData;
import com.medical.data.service.*;
import com.medical.data.utils.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 基本信息 前端控制器
 * </p>
 *
 * @author cj
 * @since 2024-01-23
 */
@RestController
@RequestMapping("/front/desk")
@Api(description = "工作台")
@Slf4j
public class DeskController {
    @Autowired
    private DataCollectorService dataCollectorService;

    @Autowired
    private PatientService patientService;

    @Autowired
    private ProjectDataService projectDataService;

    @Autowired
    private FormDataService formDataService;

    @Autowired
    private FormTemplateService formTemplateService;



    @ApiOperation("工作台接口,一个接口把事干完")
    @PostMapping("/index")
    public Result dataCollect() {
        Map<String,Object>map=new HashMap<>();
        map = dataCollectorService.getData();
        return Result.ok().data("map",map);
    }
}

